package com.mrd.gtimp.business.entity;

import org.hibernate.annotations.GenericGenerator;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;

/**
 * Created by dark on 17/7/10.
 */

/**
 * 查验跟踪，单柜的查验内容、结果结果。
 */
@Entity(name = "T_BIZ_DECLA_CHECK_TRACKING")
public class DeclaCheckTracking implements Serializable {
    /**
     * 编号
     */
    @Id
    @GeneratedValue(generator = "paymentableGenerator")
    @GenericGenerator(name = "paymentableGenerator", strategy = "uuid")
    @Column(name = "ID")
    private String id;
    /**
     * 报关单ID
     */
    @ManyToOne
    @JoinColumn(name = "DID")
    private Declaration declaration;
    /**
     * 创建人
     */
    @Column(name = "CREATOR")
    private String creator;
    /**
     * 创建时间
     */
    @Column(name = "CREATE_TIME")
    private Date createTime;
    /**
     * 状态
     */
    @Column(name = "STATUS")
    private String status;

    /**
     * 查验内容列表
     */
    @OneToMany(mappedBy = "declaCheckTracking", cascade = CascadeType.ALL)
    private List<DeclaCheckContent> declaCheckContentList;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getCreator() {
        return creator;
    }

    public void setCreator(String creator) {
        this.creator = creator;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public Declaration getDeclaration() {
        return declaration;
    }

    public void setDeclaration(Declaration declaration) {
        this.declaration = declaration;
    }

    public List<DeclaCheckContent> getDeclaCheckContentList() {
        return declaCheckContentList;
    }

    public void setDeclaCheckContentList(List<DeclaCheckContent> declaCheckContentList) {
        this.declaCheckContentList = declaCheckContentList;
    }
}
